
<div id="maincenterTop"></div>
<div id="maincenter">
  <div class="pagina_rankings"></div>
  <div class="pagina_centro">
    <div style="padding-top:30px; width:500px; margin-left:30px;">
      <script>
            function GetRankingLoadedOptions()
            {
                var type = "{type}";
                var param1 = "{param1}";
                var param2 = "{param2}";
                var param3 = "{param3}";

                if (type == "")
                    type = "resets";

                $("#RankingOptions").load("?c=Rankings/" + type, {}, function () {
                    $("#type").val(type);
                    $("#param1").val(param1);
                    $("#param2").val(param2);
                    $("#param3").val(param3);
                });
            }

            function GetRankingOptions()
            {
                $("#RankingOptions").empty();
                $("#RankingTable").empty();
                var type = $("#type").val();
                $("#RankingOptions").load("?c=Rankings/" + type);
            }

            function GetRanking()
            {
                var type = $("#type").val();

                var param1;
                $("#param1").length ? param1 = $("#param1").val() : param1 = "";
                var param2;
                $("#param2").length ? param2 = $("#param2").val() : param2 = "";
                var param3;
                $("#param3").length ? param3 = $("#param3").val() : param3 = "";

                //NO AJAX
                //window.location.href = "?c=Rankings/"+type+"/"+param1+"/"+param2+"/"+param3;

                //AJAX MODE
                LoadRanking("?c=Rankings/" + type + "/" + param1 + "/" + param2 + "/" + param3);
            }

            $(function () {
                GetRankingLoadedOptions();
            });
        </script>
             <div class="ranks"> <div>
            <select id="type" name="type" onChange="GetRankingOptions()">
                <option value="resets">Top Resets</option>
                <option value="level">Level</option>
                <option value="guilds">Top Guilds</option>
                <!-- 
                <option value="events">Eventos</option>
                <option value="gens">Gens</option>
                <option value="duel">Duel</option> -->
                <option value="pk">PK - Hero</option>
                <option value="online">Tempo Online</option>
            </select>
        </div>
        <div id="RankingOptions"></div>
        <hr />
    </div>
    <div class="ranks" style="width:520px; margin-left:25px;" id="RankingTable">{ranking}</div>
  </div>  <div class="pagina_footer"></div>
</div>